/*
 * This file (RxXavFilter.java) is protected by the GNU GPL licence (v2). 
 * Please read the license.txt attached for further informations. 
 * 
 */

package alkwarel.filters;

import alkwarel.objects.RxSimpleFilter;

/**
 * @author Xavier Gouchet
 *
 */
public class RxCycle extends RxSimpleFilter {

	/**
	 * Standard Constructor
	 */
	public RxCycle() {
		super(2, "cycle");
	}

	/**
	 * @see alkwarel.objects.RxSimpleFilter#FilterPixel()
	 */
	protected void FilterPixel() {
		float nh = ((float) this.vval )/255.0f;
		float ns = ((float) this.hhue)/360.0f;
		float nv = ((float) this.ssat)/1000.0f;
		this.H((int) (nh*360));
		this.S((int) (ns*1000));
		this.V((int) (nv*255));
	}

}
